package com.qiang.test04;

import java.io.IOException;
import java.io.InputStream;
import java.util.Properties;
import java.util.Set;

public class Demo01 {
    public static void main(String[] args) throws IOException {
        ClassLoader sc = ClassLoader.getSystemClassLoader();
        InputStream ra = sc.getResourceAsStream("prop.properties");
        Properties pp = new Properties();
        pp.load(ra);
        ra.close();
        //System.out.println(pp);
        Set<Object> keyset = pp.keySet();
        for (Object key : keyset) {
            Object value = pp.get(key);
            System.out.println(key+"==="+value);
        }
    }
}
